//
//  NSDateFormatter+TYCreated.m
//  TYFoundation
//
//  Created by 郭艺伟 on 2019/2/28.
//

#import "NSDateFormatter+TYCreated.h"

@implementation NSDateFormatter (TYCreated)

+ (NSDateFormatter *)ty_ISO8601DateFormatter {
    NSDateFormatter *dateFormatter = [[NSDateFormatter alloc] init];
    NSLocale *enUSPOSIXLocale = [NSLocale localeWithLocaleIdentifier:@"en_US_POSIX"];
    [dateFormatter setLocale:enUSPOSIXLocale];
    [dateFormatter setDateFormat:@"yyyy-MM-dd'T'HH:mm:ss.SSSZZZZZ"];
    return dateFormatter;
}

@end
